<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>js函数</title>
</head>
<body>
<script>
  //声明一
  function add(a,b){
    return a+b;
  }
  //声明二
  var fAdd = function(a,b){
    return a+b;
  }

  //调用
  let r1 = add(1,2);
  let r2 = add("a","b");
  let r3 = add(1,fAdd);
  console.log(r1,r2,r3,typeof fAdd);
</script>
</body>
</html>